export class UserManhuaBase{

    constructor(public util,public router){}

    checkInput(event,manhua){
        // console.log(event);
        if(event.target.nodeName === 'INPUT'){
            return;
        }else{
            manhua.deleteBool = !manhua.deleteBool;
        }
    }

    // go to detail page
    goDetail(manhua) {

        let data = Object.assign({}, manhua);
        data['_id'] = data['manhuaId'];
        this.util.sessionStore().set('manhuaDetail', data);
        this.router.navigate(['/manhua', manhua.title]);
    }
}